<?php


namespace Yond\LaravelDomain\Console\Domain;

use Illuminate\Support\Str;
use Yond\LaravelDomain\Console\DomainGenerator;

class EnumMakeCommand extends DomainGenerator
{

    /**
     * The name and signature of the console command.
     *
     * @var string
     */
    protected $signature = 'yond:domain:enum {--enum= : The name of the enum}';

    /**
     * The console command description.
     *
     * @var string
     */
    protected $description = 'Make a domain enum';

    protected function getUserInputs()
    {
        $enum = ucfirst($this->optionOrAsk('enum', 'Please enter the name of the enum to make'));

        return [
            'path' => [
                'domain' => $this->domainName,
                'enum' => $enum,
            ],
            'stub' => [
                'class' => $enum,
                'domain' => $this->domainName,
            ]
        ];
    }

    protected function getStubName(): string
    {
        return 'enum.stub';
    }

    protected function getPathStructure()
    {
        return 'domain/{domain}/Enums/{enum}.php';
    }
}
